<!-- ============================ Sidebar Start ============================ -->

<aside class="sidebar">
    <!-- sidebar close btn -->
    <button type="button" class="sidebar-close-btn text-gray-500 hover-text-white hover-bg-main-600 text-md w-24 h-24 border border-gray-100 hover-border-main-600 d-xl-none d-flex flex-center rounded-circle position-absolute"><i class="ph ph-x"></i></button>
    <!-- sidebar close btn -->

    <a href="/" class="sidebar__logo text-center p-20 position-sticky inset-block-start-0 bg-white w-100 z-1 pb-10">
        <img src="/static/img/logo.png" alt="Logo">
    </a>

    <div class="sidebar-menu-wrapper overflow-y-auto scroll-sm">
        <div class="p-20 pt-10">
            <ul class="sidebar-menu">
                <li class="sidebar-menu__item">
                    <a href="/control/" class="sidebar-menu__link">
                        <span class="icon"><i class="ph ph-house"></i></span>
                        <span class="text">首页</span>
                    </a>
                </li>
                <li class="sidebar-menu__item has-dropdown<?php if($history_type){echo ' activePage';}?>">
                    <a href="#" class="sidebar-menu__link">
                        <span class="icon"><i class="ph ph-clock-counter-clockwise"></i></span>
                        <span class="text">历史记录</span>
                    </a>
                    <!-- Submenu start -->
                    <ul class="sidebar-submenu">
                        <li class="sidebar-submenu__item<?php if($history_type==1){echo ' activePage';}?>">
                            <a href="/control/textlist.php?type=view_history" class="sidebar-submenu__link">
                                <span class="icon"><i class="ph ph-clock-clockwise"></i></span>
                                <span class="text">浏览记录</span></a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($history_type==2){echo ' activePage';}?>">
                            <a href="/control/textlist.php?type=so_history" class="sidebar-submenu__link"> <span class="icon"><i class="ph ph-magnifying-glass"></i></span>
                                <span class="text">搜索记录</span> </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($history_type==3){echo ' activePage';}?>">
                            <a href="/control/textlist.php?type=comments_history" class="sidebar-submenu__link"> <span class="icon"><i class="ph ph-chat-centered-dots"></i></span>
                                <span class="text">我的评论</span> </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($history_type==10){echo ' activePage';}?>">
                            <a href="/control/userlist.php?type=follow" class="sidebar-submenu__link"> <span class="icon"><i class="ph ph-eye"></i></span>
                                <span class="text">我的关注</span> </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($history_type==4){echo ' activePage';}?>">
                            <a href="/control/notelist.php?type=like" class="sidebar-submenu__link"> <span class="icon"><i class="ph ph-heart"></i></span>
                                <span class="text">我的点赞</span> </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($history_type==5){echo ' activePage';}?>">
                            <a href="/control/notelist.php?type=star" class="sidebar-submenu__link"> <span class="icon"><i class="ph ph-star"></i></span>
                                <span class="text">我的收藏</span> </a>
                        </li>
                    </ul>
                    <!-- Submenu End -->
                </li>
                <li class="sidebar-menu__item has-dropdown<?php if($info_type){echo ' activePage';}?>">
                    <a href="#" class="sidebar-menu__link">
                        <span class="icon"><i class="ph ph-note"></i></span>
                        <span class="text">笔记管理</span>
                    </a>
                    <!-- Submenu start -->
                    <ul class="sidebar-submenu">
                        <li class="sidebar-submenu__item<?php if($edit_note==1){echo ' activePage';}?>">
                            <a href="/control/edit.php" class="sidebar-submenu__link"> 发布笔记 </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($info_type==1){echo ' activePage';}?>">
                            <a href="/control/notelist.php" class="sidebar-submenu__link"> 笔记列表 </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($info_type==2){echo ' activePage';}?>">
                            <a href="/control/notelist.php?type=nocheck" class="sidebar-submenu__link"> 待审笔记 </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($info_type==3){echo ' activePage';}?>">
                            <a href="/control/notelist.php?type=cantcheck" class="sidebar-submenu__link"> 违规笔记 </a>
                        </li>
                    </ul>
                    <!-- Submenu End -->
                </li>
                <li class="sidebar-menu__item<?php if($ulist_type){echo ' activePage';}?> has-dropdown">
                    <a href="javascript:void(0)" class="sidebar-menu__link">
                        <span class="icon"><i class="ph ph-chart-bar"></i></span>
                        <span class="text">数据看板</span>
                    </a>
                    <!-- Submenu start -->
                    <ul class="sidebar-submenu">
                        <li class="sidebar-submenu__item<?php if($ulist_type==2){echo ' activePage';}?>">
                            <a href="/control/userlist.php?type=like" class="sidebar-submenu__link"> 赞与收藏 </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($ulist_type==3){echo ' activePage';}?>">
                            <a href="/control/userlist.php?type=onlylike" class="sidebar-submenu__link"> 获赞详情 </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($ulist_type==4){echo ' activePage';}?>">
                            <a href="/control/userlist.php?type=onlystar" class="sidebar-submenu__link"> 收藏详情 </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($ulist_type==1){echo ' activePage';}?>">
                            <a href="/control/userlist.php" class="sidebar-submenu__link"> 粉丝详情 </a>
                        </li>
                        <li class="sidebar-submenu__item<?php if($ulist_type==10){echo ' activePage';}?>">
                            <a href="/control/textlist.php?type=all_comments" class="sidebar-submenu__link"> 评论详情 </a>
                        </li>
                        <!--<li class="sidebar-submenu__item">
                            <a href="/control/analytics.html" class="sidebar-submenu__link"> 数据概览 </a>
                        </li>-->
                    </ul>
                    <!-- Submenu End -->
                </li>
                <li class="sidebar-menu__item<?php if($pageName=="笔记审核"){echo ' activePage';}?>">
                    <a href="/control/checker.php" class="sidebar-menu__link">
                        <span class="icon"><i class="ph ph-cloud-check"></i></span>
                        <span class="text">笔记审核</span>
                    </a>
                </li>



                <li class="sidebar-menu__item">
                    <span class="text-gray-300 text-sm px-20 pt-20 fw-semibold border-top border-gray-100 d-block text-uppercase">设置</span>
                </li>
                <li class="sidebar-menu__item">
                    <a href="setting.php" class="sidebar-menu__link">
                        <span class="icon"><i class="ph ph-gear"></i></span>
                        <span class="text">账号设置</span>
                    </a>
                </li>

            </ul>
        </div>

    </div>

</aside>
<!-- ============================ Sidebar End  ============================ -->